# -!- coding: utf-8 -!-
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
1.获取渠道资金项目数据库的信息生成相应的对账文件
2.获取数据库信息并对信息进行组合
3.更新数据库字段信息
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

from msydwork.config.config_qdzj import cursor,db


# 薪计划通过业务流水号 unique_id 获取订单号order_no
def get_order(unique_id):
    cursor.execute('select order_no from xjh_apply_record where unique_id = "%s";' %(unique_id))
    try:
        order_no = cursor.fetchone()  # 获取一条数据
        db.commit()
        #print (order_no[0])
        return(order_no[0])
    except:
        print('查无数据！')


if __name__ == '__main__':
    get_order('APXJH202011111722520001')

